package cn.lanca.gof6_10._06proxy.case2.proxy;

import com.example.demo.gof6_10._06proxy.case2.abstract_subject.Specialty;
import com.example.demo.gof6_10._06proxy.case2.real_subject.WySpecialty;

/**
 * 代理：韶关代理
 *
 * @author meihongliang
 * @since 2020/8/10 14:43
 */
public class SgProxy implements Specialty {
    private WySpecialty realSubject = new WySpecialty();

    /**
     * display
     */
    @Override
    public void display() {
        preRequest();
        realSubject.display();
        postRequest();
    }

    public void preRequest() {
        System.out.println("韶关代理婺源特产开始。");
    }

    public void postRequest() {
        System.out.println("韶关代理婺源特产结束。");
    }
}
